<?php echo doctype('html5'); ?>
<html lang="en">

	<head>
		<title><?php echo $title; ?> -UME Leave Request</title>
		<link rel="shortcut icon" href="<?php echo base_url(); ?>bootstrap/icons/favicon.ico" type="image/x-ico; charset=binary"/>
		<link rel="icon" href="<?php echo base_url(); ?>bootstrap/icons/favicon.ico" type="image/x-ico; charset=binary" />
		<?php
		$metas = array(
			array('name' => 'Content-type', 'content' => 'text/html; charset=utf-8', 'type' => 'equiv'),
			array('name' => 'robots', 'content' => 'no-cache'),
			array('name' => 'description', 'content' => 'UME Leave Request'),
			array('name' => 'keywords', 'content' => 'leave request, UME leave request, leave request form, UME form leave request'),
			array('name' => 'author', 'content' => 'group 5 of vc 2')
		);
		echo meta($metas);
		?>
		<!-- Le styles -->

		<?php
		echo link_tag(base_url("bootstrap/css/bootstrap.css"));
		echo link_tag(base_url("bootstrap/css/bootstrap-responsive.css"));
		echo link_tag(base_url("bootstrap/css/style.css"));
		echo link_tag(base_url("bootstrap/css/demo_table_jui.css"));
		if (!PNC_Controller::check_session()) {
			echo link_tag(base_url("bootstrap/css/login.css"));
		}
		?>
		<!-- HTML5 shim, for IE6-8 support of HTML5 elements -->
		<!--[if lt IE 9]>
		  <script src="../assets/js/html5shiv.js"></script>
		<![endif]-->
	</head>

	<body>
		<div class="container">
			<?php
			if ($this->session->userdata('admin') || $this->session->userdata('gm') || $this->session->userdata('staff') || $this->session->userdata('manager') || $this->session->userdata('submanager')) {
				$img_logo = array(
					'src' => 'bootstrap/img/logo.png',
					'alt' => 'logo',
					'class' => 'img_logo'
				);
//				$img_banner = array(
//					'src' => 'images/banner/PN1.jpg',
//					'alt' => 'logo',
//					'class' => 'img_banner pull-left'
//				);
				?>
				<div class="masthead"> <!--/* -- header -- */-->
					<div id="row-fluid" class="row ma-b-100">
						<div id="head_img" class="span8 slogan">
                    

							<!--<h2 id="txt_UME" class="txt_UME">
							<?php /* echo strtoupper(PNC_Controller::PNC); */ ?>
								</h2>
								<h3 id="txt_gateway" class="txt_UME">
							<?php /* echo PNC_Controller::GATEWAY; */ ?>
								</h3>-->
							<?php // echo img($img_banner); ?>	
							<?php echo img($img_logo); ?>
                            
						</div>


					</div>
					<div class="row">
						<div class="span9">
							<h4 id="txt_lr" class="pull-right">
								<?php echo strtoupper(PNC_Controller::LEAVING); ?>
							</h4>
						</div>
						<div id="span4-logout" class="span3">
							<div class="user-setting">
								<?php
								if ($this->session->userdata('admin')) {
									$this->load->view("logout/logout_admin");
								} else if ($this->session->userdata('manager')) {
									$this->load->view("logout/logout_manager");
								} else if ($this->session->userdata('gm')) {
									$this->load->view("logout/logout_gm");
								} else if ($this->session->userdata('staff')) {
									$this->load->view("logout/logout_staff");
								} else if ($this->session->userdata('submanager')) {
									$this->load->view("logout/logout_submanager");
								}
								?>
							</div>
						</div>
					</div>
					<div class="navbar main-nav">
						<div id="navbar-inner" class="navbar-inner">
							<div id="container" class="container">
								<?php
								if ($this->session->userdata('admin')) {
									$this->load->view('incs/menu');
								} else if ($this->session->userdata('manager')) {
									$this->load->view('incs/menu_manager');
								} else if ($this->session->userdata('gm')) {
									$this->load->view("incs/menu_gm");
								} else if ($this->session->userdata("staff")) {
									$this->load->view("incs/menu_staff");
								} else if ($this->session->userdata("submanager")) {
									$this->load->view("incs/menu_submanager");
								}
								?>
							</div>
						</div>
					</div>	<!-- /* -- /.navbar -- */ -->
				</div>	<!-- /* -- /.masthead -- */-->
				<br />
				<?php
			} else {
				?>
				<div class="navbar">
					<div id="inner" class="navbar-inner"> 	
						<h4>Welcome to UME Leaving Request</h4>
					</div>
				</div>
				<?php
			}
			?>
			<div class="container-fluid" id="container-fluid"><!-- Content or body -->
				<br />
				<?php
				/* Show message when have logout */
				if ($this->session->userdata('login_erro')) {
					echo $this->session->userdata('login_erro');
					$this->session->unset_userdata('login_erro');
				} else if ($this->session->userdata('logout')) {
					echo $this->session->userdata('logout');
					$this->session->unset_userdata('logout');
				} else if ($this->session->userdata('send_reset_success')) {
					echo $this->session->userdata('send_reset_success');
					$this->session->unset_userdata('send_reset_success');
				}
				if (!$this->uri->segment(2)) {
					$this->load->view('main/login');
				} else {
					$this->load->view($this->uri->segment(1) . '/' . $this->uri->segment(2));
				}
				echo br(2);
				?>
			</div><!--/.fluid-container--><br />
			<div class="container-fluid">
				<div class="row-fluid">
					<footer class="mark-style">	
						<p class="pull-left">
							&copy; <?php echo anchor('http://www.ume-kpc.edu.kh', 'UME', 'target="_blank"') . nbs(); ?>2013
						</p>
						<p class="pull-right">
			Powered by :<?php echo anchor('http://www.ume-kpc.edu.kh/', ' KITS\'s Team'); ?>
						</p>
					</footer>
				</div>
			</div>
		</div> <!-- /container -->

		<?php
		echo include_js(array('bootstrap/js/jquery.min.js', 'bootstrap/js/bootstrap.min.js', 'bootstrap/js/jquery-ui.min.js', 'bootstrap/js/general.js', 'bootstrap/js/jquery.dataTables.min.js'));
		?>

	</body>
</html>